<?php

function loadImg($img_path) {
    $dir = opendir($img_path) or die("LA CARTELLA NON PUo' ESSERE APERTA" . $img_path);
    $index=1;
    while (false !== ($file = readdir($dir))) {
        if ($file != "." && $file != ".." && substr($file, 0, 1)!=".") {
            echo "<img  id=\"image".$index."\" class=\"resizeme\"  src=\"$img_path$file\" align=\"center\"></img>\n";
//            class=\"resizeme\"
        }
        $index++;
    }
}
?>